home *** CD-ROM | disk | FTP | other *** search
/ 1000 Apple LAN Literacy / 1000 Apple LAN Literacy.iso / Apple LAN Literacy / Literacy Segments Part 1 / Literacy Segments Part 1 / background_78546.txt < prev    next >
Text File  |  1989-08-22  |  13KB  |  593 lines

  1. -- background: 78546 from stack: in
  2. -- bmap block id: 78657
  3. -- flags: 0000
  4. -- background id: 0
  5. -- name: 1.2.1 Practice2
  6. ----- HyperTalk script -----
  7. on openCard
  8.   global answerTracker
  9.   send mouseUp to bg btn "done"
  10.   put line (line 2 of fld "key") of answerTracker into theLocs
  11.   if theLocs is not empty then
  12.     repeat with i = 1 to number of lines in fld "origins"
  13.       get item (i*2 - 1) to (i*2) of theLocs
  14.       set the loc of bg btn (i + 9) to it
  15.     end repeat
  16.   else
  17.     repeat with j = 1 to number of lines in fld "origins"
  18.       set the loc of bg btn (j + 9) to (line j of fld "origins")
  19.     end repeat
  20.   end if
  21.   pass openCard
  22. end openCard
  23.  
  24. on closeCard
  25.   global answerTracker
  26.   get line 2 of fld "key"  -- says which line of global to worry about
  27.   put empty into line it of answerTracker
  28.   repeat with i = 1 to number of lines in fld "origins"
  29.     put the loc of bg btn (i + 9) & "," after line it of answerTracker
  30.   end repeat
  31.   delete last char of line it of answerTracker
  32.   pass closeCard
  33. end closeCard
  34.  
  35. on moveButton
  36.   get fld "decisions"
  37.   repeat until the mouse is up
  38.     if item 2 of the mouseLoc > line 1 of it
  39.     then set the loc of the target to the mouseLoc
  40.   end repeat
  41.   put the loc of the target into temp
  42.   if item 1 of the loc of the target > (line 2 of it) then
  43.     if item 2 of the loc of the target < (line 3 of it) then
  44.       validate (line 1 of fld "destinations")
  45.     else if item 2 of the loc of the target < (line 4 of it) then
  46.       validate (line 2 of fld "destinations")
  47.     else validate (line 3 of fld "destinations")
  48.   end if
  49.   if the loc of the target = temp
  50.   then set the loc of the target to line (number of the target - 9) of fld "origins"
  51. end moveButton
  52.  
  53. on validate where
  54.   repeat with i = 1 to number of lines in fld "origins"
  55.     if the number of the target = (i + 9) then next repeat
  56.     if the loc of bg btn (i + 9) = where then exit validate
  57.   end repeat
  58.   set the loc of the target to where
  59. end validate
  60.  
  61. on hideFeedback
  62.   lock screen
  63.   hide fld "Feedback1"
  64.   hide fld "Feedback2"
  65.   hide fld "Feedback3"
  66.   hide fld "Feedback4"
  67.   hide fld "Feedback5"
  68.   hide fld "CorrectAnswer"
  69.   hide fld "MasterFeedback"
  70.   hide bg btn "Done"
  71.   unlock screen
  72. end hideFeedback
  73.  
  74. on showFeedback
  75.   lock screen
  76.   show fld "Feedback1"
  77.   show fld "Feedback2"
  78.   show fld "Feedback3"
  79.   show fld "Feedback4"
  80.   show fld "Feedback5"
  81.   show fld "CorrectAnswer"
  82.   show fld "MasterFeedback"
  83.   show bg btn "Done"
  84.   unlock screen
  85. end showFeedback
  86.  
  87.  
  88. -- part 3 (field)
  89. -- low flags: 01
  90. -- high flags: 0000
  91. -- rect: left=18 top=1 right=38 bottom=442
  92. -- title width / last selected line: 0
  93. -- icon id / first selected line: 0 / 0
  94. -- text alignment: 0
  95. -- font id: 156
  96. -- text size: 24
  97. -- style flags: 10240
  98. -- line height: 32
  99. -- part name: Title
  100.  
  101.  
  102. -- part 14 (button)
  103. -- low flags: 00
  104. -- high flags: 0000
  105. -- rect: left=443 top=5 right=72 bottom=512
  106. -- title width / last selected line: 0
  107. -- icon id / first selected line: 0 / 0
  108. -- text alignment: 1
  109. -- font id: 0
  110. -- text size: 12
  111. -- style flags: 0
  112. -- line height: 16
  113. -- part name: Instant Reference
  114. ----- HyperTalk script -----
  115. on mouseUp
  116.   instantReference "1.2.1"
  117. end mouseUp
  118.  
  119.  
  120. -- part 15 (button)
  121. -- low flags: 00
  122. -- high flags: 2000
  123. -- rect: left=480 top=143 right=172 bottom=511
  124. -- title width / last selected line: 0
  125. -- icon id / first selected line: 1310 / 1310
  126. -- text alignment: 1
  127. -- font id: 0
  128. -- text size: 12
  129. -- style flags: 0
  130. -- line height: 16
  131. -- part name: Student Services
  132. ----- HyperTalk script -----
  133. on mousedown
  134.   SSpopUp
  135. end mousedown
  136.  
  137. on mouseup
  138.   if the mouseloc is not within the rect of me then exit to hyperCard
  139.   doSS
  140. end mouseup
  141.  
  142.  
  143.  
  144. -- part 16 (button)
  145. -- low flags: 00
  146. -- high flags: 2000
  147. -- rect: left=482 top=176 right=205 bottom=511
  148. -- title width / last selected line: 0
  149. -- icon id / first selected line: 162 / 162
  150. -- text alignment: 1
  151. -- font id: 0
  152. -- text size: 12
  153. -- style flags: 0
  154. -- line height: 16
  155. -- part name: Help
  156. ----- HyperTalk script -----
  157. on mouseUp
  158.   Help
  159. end mouseUp
  160.  
  161.  
  162.  
  163. -- part 17 (button)
  164. -- low flags: 00
  165. -- high flags: 2000
  166. -- rect: left=482 top=294 right=320 bottom=509
  167. -- title width / last selected line: 0
  168. -- icon id / first selected line: 1236 / 1236
  169. -- text alignment: 1
  170. -- font id: 0
  171. -- text size: 12
  172. -- style flags: 0
  173. -- line height: 16
  174. -- part name: Last Menu
  175. ----- HyperTalk script -----
  176. on mouseUp
  177.   go to card "Links and Nodes P/1"
  178. end mouseUp
  179.  
  180.  
  181.  
  182.  
  183. -- part 18 (button)
  184. -- low flags: 00
  185. -- high flags: 0000
  186. -- rect: left=478 top=319 right=341 bottom=498
  187. -- title width / last selected line: 0
  188. -- icon id / first selected line: 1401 / 1401
  189. -- text alignment: 1
  190. -- font id: 0
  191. -- text size: 12
  192. -- style flags: 0
  193. -- line height: 16
  194. -- part name: Prev
  195. ----- HyperTalk script -----
  196. on mouseUp
  197.  
  198. end mouseUp
  199.  
  200.  
  201.  
  202. -- part 19 (button)
  203. -- low flags: 00
  204. -- high flags: 0000
  205. -- rect: left=493 top=319 right=341 bottom=512
  206. -- title width / last selected line: 0
  207. -- icon id / first selected line: 1400 / 1400
  208. -- text alignment: 1
  209. -- font id: 0
  210. -- text size: 12
  211. -- style flags: 0
  212. -- line height: 16
  213. -- part name: Next
  214. ----- HyperTalk script -----
  215. on mouseUp
  216.  
  217. end mouseUp
  218.  
  219.  
  220.  
  221. -- part 20 (field)
  222. -- low flags: 01
  223. -- high flags: 0000
  224. -- rect: left=16 top=38 right=65 bottom=437
  225. -- title width / last selected line: 0
  226. -- icon id / first selected line: 0 / 0
  227. -- text alignment: 0
  228. -- font id: 156
  229. -- text size: 20
  230. -- style flags: 0
  231. -- line height: 26
  232. -- part name: Subtitle
  233.  
  234.  
  235. -- part 21 (field)
  236. -- low flags: 01
  237. -- high flags: 0000
  238. -- rect: left=16 top=68 right=88 bottom=470
  239. -- title width / last selected line: 0
  240. -- icon id / first selected line: 0 / 0
  241. -- text alignment: 0
  242. -- font id: 3
  243. -- text size: 10
  244. -- style flags: 256
  245. -- line height: 15
  246. -- part name: Instruction
  247.  
  248.  
  249. -- part 23 (field)
  250. -- low flags: 01
  251. -- high flags: 0000
  252. -- rect: left=161 top=129 right=166 bottom=472
  253. -- title width / last selected line: 0
  254. -- icon id / first selected line: 0 / 0
  255. -- text alignment: 0
  256. -- font id: 156
  257. -- text size: 16
  258. -- style flags: 0
  259. -- line height: 17
  260. -- part name: Item1
  261.  
  262.  
  263. -- part 24 (field)
  264. -- low flags: 01
  265. -- high flags: 0000
  266. -- rect: left=161 top=183 right=219 bottom=472
  267. -- title width / last selected line: 0
  268. -- icon id / first selected line: 0 / 0
  269. -- text alignment: 0
  270. -- font id: 156
  271. -- text size: 16
  272. -- style flags: 0
  273. -- line height: 17
  274. -- part name: Item2
  275.  
  276.  
  277. -- part 25 (field)
  278. -- low flags: 01
  279. -- high flags: 0000
  280. -- rect: left=161 top=239 right=276 bottom=472
  281. -- title width / last selected line: 0
  282. -- icon id / first selected line: 0 / 0
  283. -- text alignment: 0
  284. -- font id: 156
  285. -- text size: 16
  286. -- style flags: 0
  287. -- line height: 17
  288. -- part name: Item3
  289.  
  290.  
  291. -- part 35 (field)
  292. -- low flags: 81
  293. -- high flags: 2007
  294. -- rect: left=8 top=36 right=94 bottom=231
  295. -- title width / last selected line: 0
  296. -- icon id / first selected line: 0 / 0
  297. -- text alignment: 0
  298. -- font id: 156
  299. -- text size: 16
  300. -- style flags: 0
  301. -- line height: 17
  302. -- part name: Feedback1
  303.  
  304.  
  305. -- part 43 (field)
  306. -- low flags: 81
  307. -- high flags: 2007
  308. -- rect: left=8 top=97 right=155 bottom=231
  309. -- title width / last selected line: 0
  310. -- icon id / first selected line: 0 / 0
  311. -- text alignment: 0
  312. -- font id: 156
  313. -- text size: 16
  314. -- style flags: 0
  315. -- line height: 17
  316. -- part name: Feedback2
  317.  
  318.  
  319. -- part 37 (field)
  320. -- low flags: 81
  321. -- high flags: 2007
  322. -- rect: left=8 top=159 right=216 bottom=231
  323. -- title width / last selected line: 0
  324. -- icon id / first selected line: 0 / 0
  325. -- text alignment: 0
  326. -- font id: 156
  327. -- text size: 16
  328. -- style flags: 0
  329. -- line height: 17
  330. -- part name: Feedback3
  331.  
  332.  
  333. -- part 38 (field)
  334. -- low flags: 81
  335. -- high flags: 2007
  336. -- rect: left=8 top=219 right=277 bottom=231
  337. -- title width / last selected line: 0
  338. -- icon id / first selected line: 0 / 0
  339. -- text alignment: 0
  340. -- font id: 156
  341. -- text size: 16
  342. -- style flags: 0
  343. -- line height: 17
  344. -- part name: Feedback4
  345.  
  346.  
  347. -- part 40 (field)
  348. -- low flags: 81
  349. -- high flags: 2007
  350. -- rect: left=8 top=280 right=338 bottom=231
  351. -- title width / last selected line: 0
  352. -- icon id / first selected line: 0 / 0
  353. -- text alignment: 0
  354. -- font id: 156
  355. -- text size: 16
  356. -- style flags: 0
  357. -- line height: 17
  358. -- part name: CorrectAnswer
  359.  
  360.  
  361. -- part 41 (field)
  362. -- low flags: 81
  363. -- high flags: 2004
  364. -- rect: left=147 top=132 right=304 bottom=356
  365. -- title width / last selected line: 0
  366. -- icon id / first selected line: 0 / 0
  367. -- text alignment: 0
  368. -- font id: 156
  369. -- text size: 16
  370. -- style flags: 0
  371. -- line height: 17
  372. -- part name: MasterFeedback
  373.  
  374.  
  375. -- part 39 (field)
  376. -- low flags: 81
  377. -- high flags: 2007
  378. -- rect: left=238 top=32 right=89 bottom=461
  379. -- title width / last selected line: 0
  380. -- icon id / first selected line: 0 / 0
  381. -- text alignment: 0
  382. -- font id: 156
  383. -- text size: 16
  384. -- style flags: 0
  385. -- line height: 17
  386. -- part name: Feedback5
  387.  
  388.  
  389. -- part 42 (button)
  390. -- low flags: 80
  391. -- high flags: A002
  392. -- rect: left=215 top=279 right=296 bottom=284
  393. -- title width / last selected line: 0
  394. -- icon id / first selected line: 0 / 0
  395. -- text alignment: 1
  396. -- font id: 0
  397. -- text size: 12
  398. -- style flags: 0
  399. -- line height: 16
  400. -- part name: Done
  401. ----- HyperTalk script -----
  402. on mouseUp
  403.   lock screen
  404.   hide fld "MasterFeedback"
  405.   hide bg btn "Done"
  406.   unlock screen
  407. end mouseUp
  408.  
  409.  
  410.  
  411. -- part 5 (field)
  412. -- low flags: 81
  413. -- high flags: 0001
  414. -- rect: left=423 top=0 right=13 bottom=466
  415. -- title width / last selected line: 0
  416. -- icon id / first selected line: 0 / 0
  417. -- text alignment: 65535
  418. -- font id: 4
  419. -- text size: 9
  420. -- style flags: 0
  421. -- line height: 12
  422. -- part name: CardTitle
  423.  
  424.  
  425. -- part 44 (button)
  426. -- low flags: 00
  427. -- high flags: A004
  428. -- rect: left=268 top=321 right=340 bottom=413
  429. -- title width / last selected line: 0
  430. -- icon id / first selected line: 0 / 0
  431. -- text alignment: 1
  432. -- font id: 0
  433. -- text size: 12
  434. -- style flags: 0
  435. -- line height: 16
  436. -- part name: Answer
  437. ----- HyperTalk script -----
  438. on mouseUp
  439.   send mouseUp to bg btn "Done"
  440.   repeat with i = 1 to number of lines in fld "origins"
  441.     set the loc of bg btn (i + 9) to (line i of fld "origins")
  442.   end repeat
  443.   put line 1 of fld "key" into theLocs
  444.   repeat with i = 1 to number of lines in fld "origins"
  445.     get item (i*2 - 1) to (i*2) of theLocs
  446.     set the loc of bg btn (i + 9) to it
  447.   end repeat
  448. end mouseUp
  449.  
  450.  
  451. -- part 63 (button)
  452. -- low flags: 00
  453. -- high flags: A004
  454. -- rect: left=68 top=321 right=340 bottom=213
  455. -- title width / last selected line: 0
  456. -- icon id / first selected line: 0 / 0
  457. -- text alignment: 1
  458. -- font id: 0
  459. -- text size: 12
  460. -- style flags: 0
  461. -- line height: 16
  462. -- part name: Check Answer
  463. ----- HyperTalk script -----
  464. on mouseUp
  465.   lock screen
  466.   set cursor to watch
  467.   put empty into theList
  468.   get line 1 of fld "key"
  469.   repeat with i = 1 to (number of items in it)/2
  470.     put item (i*2 - 1) of it & "," & item (i*2) of it into theLoc
  471.     if the loc of bg btn (i + 9) = theLoc then put "t," after theList
  472.     else put "f," after theList
  473.   end repeat
  474.   delete last char of theList
  475.   if theList = "t,t" then put fld "feedback1" into fld "masterFeedback"
  476.   if theList = "t,f" then put fld "feedback2" into fld "masterFeedback"
  477.   if theList = "f,t" then put fld "feedback3" into fld "masterFeedback"
  478.   if theList = "f,f" then put fld "feedback4" into fld "masterFeedback"
  479.   show fld "MasterFeedback"
  480.   show bg btn "Done"
  481.   unlock screen
  482. end mouseUp
  483.  
  484.  
  485. -- part 54 (button)
  486. -- low flags: 00
  487. -- high flags: 8000
  488. -- rect: left=30 top=157 right=201 bottom=67
  489. -- title width / last selected line: 0
  490. -- icon id / first selected line: 7802 / 7802
  491. -- text alignment: 1
  492. -- font id: 0
  493. -- text size: 12
  494. -- style flags: 0
  495. -- line height: 16
  496. -- part name: Link
  497. ----- HyperTalk script -----
  498. on mouseDown
  499.   moveButton
  500. end mouseDown
  501.  
  502.  
  503. -- part 55 (button)
  504. -- low flags: 00
  505. -- high flags: 8000
  506. -- rect: left=30 top=208 right=252 bottom=66
  507. -- title width / last selected line: 0
  508. -- icon id / first selected line: 6727 / 6727
  509. -- text alignment: 1
  510. -- font id: 0
  511. -- text size: 12
  512. -- style flags: 0
  513. -- line height: 16
  514. -- part name: Node
  515. ----- HyperTalk script -----
  516. on mouseDown
  517.   moveButton
  518. end mouseDown
  519.  
  520.  
  521. -- part 58 (button)
  522. -- low flags: 00
  523. -- high flags: 2000
  524. -- rect: left=482 top=208 right=234 bottom=509
  525. -- title width / last selected line: 0
  526. -- icon id / first selected line: 1234 / 1234
  527. -- text alignment: 1
  528. -- font id: 0
  529. -- text size: 12
  530. -- style flags: 0
  531. -- line height: 16
  532. -- part name: Lesson
  533. ----- HyperTalk script -----
  534. on mouseUp
  535.   lesson "1.2.1"
  536. end mouseUp
  537.  
  538.  
  539. -- part 59 (field)
  540. -- low flags: 81
  541. -- high flags: 0002
  542. -- rect: left=0 top=0 right=39 bottom=53
  543. -- title width / last selected line: 0
  544. -- icon id / first selected line: 0 / 0
  545. -- text alignment: 0
  546. -- font id: 3
  547. -- text size: 12
  548. -- style flags: 0
  549. -- line height: 16
  550. -- part name: origins
  551.  
  552.  
  553. -- part 60 (field)
  554. -- low flags: 81
  555. -- high flags: 0002
  556. -- rect: left=55 top=0 right=51 bottom=117
  557. -- title width / last selected line: 0
  558. -- icon id / first selected line: 0 / 0
  559. -- text alignment: 0
  560. -- font id: 3
  561. -- text size: 12
  562. -- style flags: 0
  563. -- line height: 16
  564. -- part name: destinations
  565.  
  566.  
  567. -- part 61 (field)
  568. -- low flags: 81
  569. -- high flags: 0002
  570. -- rect: left=119 top=0 right=70 bottom=153
  571. -- title width / last selected line: 0
  572. -- icon id / first selected line: 0 / 0
  573. -- text alignment: 0
  574. -- font id: 3
  575. -- text size: 12
  576. -- style flags: 0
  577. -- line height: 16
  578. -- part name: decisions
  579.  
  580.  
  581. -- part 62 (field)
  582. -- low flags: 81
  583. -- high flags: 0002
  584. -- rect: left=155 top=0 right=34 bottom=318
  585. -- title width / last selected line: 0
  586. -- icon id / first selected line: 0 / 0
  587. -- text alignment: 0
  588. -- font id: 3
  589. -- text size: 12
  590. -- style flags: 0
  591. -- line height: 16
  592. -- part name: key
  593.